/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package beatbox;

import javafx.scene.*;
import javafx.scene.shape.*;
import com.illposed.osc.*;
import javafx.scene.paint.*;
import javafx.scene.input.*;

import beatbox.ADCListener;

/**Monitors input, which it receives through OSC
 * @requires: inputMonitor.ck is chucked
 * @author Kyle
 */

public class InputMonitor extends CustomNode{
    public var preferredWidth = 100;
    public var preferredHeight = 20; 

   override function create():Node {
       Group {
        content: [Rectangle {
            width: bind preferredWidth
            height: bind preferredHeight
            fill: Color.TRANSPARENT;
            stroke: Color.BLACK;
            },
            Rectangle {
                width: bind ChuckBoard.ADC.last*preferredWidth;
                height: bind preferredHeight;
                fill: Color.RED;
            }]

        }
   }

}
